package com.ruoyi.factorydata.mapper;

import java.util.List;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.ruoyi.factorydata.domain.InventoryReceiptDetail;
import org.apache.ibatis.annotations.Param;
import org.springframework.security.core.parameters.P;

/**
 * 入库单详情Mapper接口
 *
 * @author ruoyi
 * @date 2025-07-21
 */
public interface InventoryReceiptDetailMapper extends BaseMapper<InventoryReceiptDetail> {
    /**
     * 查询入库单详情
     *
     * @param id 入库单详情主键
     * @return 入库单详情
     */
    public InventoryReceiptDetail selectInventoryReceiptDetailById(Long id);

    /**
     * 查询入库单详情列表
     *
     * @param inventoryReceiptDetail 入库单详情
     * @return 入库单详情集合
     */
    public List<InventoryReceiptDetail> selectInventoryReceiptDetailList(InventoryReceiptDetail inventoryReceiptDetail);

    /**
     * 新增入库单详情
     *
     * @param inventoryReceiptDetail 入库单详情
     * @return 结果
     */
    public int insertInventoryReceiptDetail(InventoryReceiptDetail inventoryReceiptDetail);

    /**
     * 修改入库单详情
     *
     * @param inventoryReceiptDetail 入库单详情
     * @return 结果
     */
    public int updateInventoryReceiptDetail(InventoryReceiptDetail inventoryReceiptDetail);

    /**
     * 删除入库单详情
     *
     * @param id 入库单详情主键
     * @return 结果
     */
    public int deleteInventoryReceiptDetailById(Long id);

    /**
     * 批量删除入库单详情
     *
     * @param ids 需要删除的数据主键集合
     * @return 结果
     */
    public int deleteInventoryReceiptDetailByIds(Long[] ids);

    /**
     * 根据入库单编号查询入库单预计入库统计
     *
     * @param receiptId 入库单id
     */
    Long getExpectedQuantityTotal(@Param("receiptId") Long receiptId);
}